package com.feinno.urcs.group.interop.entity;

import com.feinno.urcs.types.MobileNo;

/**
 * @author Li.Hongbo <lihongbo@feinno.com>
 */
public class DataValidateGroupMemberInfo implements DataValidatePoolInterface {
	private String mobileNo;
	private String referByMobileNo;
	private int UserId;
	private int userLogicPool;
	private int groupId;
	private int identity;

	public int getIdentity() {
		return identity;
	}

	public void setIdentity(int identity) {
		this.identity = identity;
	}


	public DataValidateGroupMemberInfo(int groupId, int userId, int userLogicPool, String mobileNo, String referByMobileNo, int identity) {
		this.mobileNo = mobileNo;
		this.referByMobileNo = referByMobileNo;
		UserId = userId;
		this.userLogicPool = userLogicPool;
		this.groupId = groupId;
		this.identity = identity;
	}

	public MobileNo getMobileNo() {
		return MobileNo.parseFrom(mobileNo);
	}

	public String getMobileStr() {
		return mobileNo;
	}

	public void setMobileNo(String mobileNo) {
		this.mobileNo = mobileNo;
	}

	public void setMobileNo(MobileNo mobileNo) {
		this.mobileNo = mobileNo.toString();
	}

	public String getReferByMobileNo() {
		return MobileNo.parseFrom(referByMobileNo).toString();
	}

	public void setReferByMobileNo(String referByMobileNo) {
		this.referByMobileNo = MobileNo.parseFrom(referByMobileNo).toString();
	}

	public void setReferByMobileNo(MobileNo referByMobileNo) {
		this.referByMobileNo = referByMobileNo.toString();
	}

	public int getUserId() {
		return UserId;
	}

	public void setUserId(int userId) {
		UserId = userId;
	}

	public int getUserLogicPool() {
		return userLogicPool;
	}

	public void setUserLogicPool(int userLogicPool) {
		this.userLogicPool = userLogicPool;
	}

	public int getGroupId() {
		return groupId;
	}

	public void setGroupId(int groupId) {
		this.groupId = groupId;
	}

	@Override
	public int getLogicPool() {
		return getUserLogicPool();
	}
}
